home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Applications / Games / Tetris / Source / TetMatrix.h < prev    next >
Text File  |  1975-04-26  |  1KB  |  52 lines

  1.  
  2. #import "Piece.h"
  3. #import "Minimatrix.h"
  4.  
  5. #define TETRIS_COLUMNS    10
  6. #define TETRIS_ROWS    25
  7. // There four different ways to view a piece: up, down, left, right
  8.  
  9. #define MIN_LEVEL    0
  10. #define MAX_LEVEL    9
  11.  
  12. @interface TetMatrix:Minimatrix
  13. {
  14.     BOOL pieceVisible;
  15.     BOOL active;
  16.     id thePiece;                      // The current piece; a Piece Object 
  17.     id scoreKeeper;
  18.     id anmBitmap;
  19.     id showNext;                      // The next piece object: NextMatrix.m
  20.      id aCheater;
  21.      id controlBox;                  // The box containing all of the controls
  22.     float level;
  23.     DPSTimedEntry timedEntryNum;
  24.     BOOL gameRunning;
  25.      BOOL colorWindow;              // canStoreColor?
  26.     double teDelay;                  // Determines how fast a piece will fall.
  27.      float anm_gameover_delta;      // The # pixels to move "Game Over" at a time
  28.      id randomFields;
  29. }
  30.  
  31. - initFrame:(const NXRect *)frameRect;
  32. - setupRandomFill:(int)max;
  33. - (BOOL)acceptsFirstResponder;
  34. - drawSelf:(const NXRect *)rects :(int)rectCount;
  35. - keyDown:(NXEvent *)theEvent;
  36.  
  37. - removeFilledRows;
  38.  
  39. - setPieceVisible:(BOOL)flag;
  40. - setScoreKeeper:keeper;
  41. - newGame:(int)theLevel;
  42. - pause:sender;
  43. - continue:sender;
  44. - stop:sender;
  45.  
  46. - startTimedEntry;
  47. - stopTimedEntry;
  48.  
  49. - free;
  50.  
  51. @end
  52.